package com.thomas.framework.entity;

import com.thomas.framework.core.EntityBase;

import java.util.Date;
import java.util.List;
import java.util.Map;
import java.util.Set;

/**
 * Created by taohj on 2014/4/19.
 */
public class SysUser  extends EntityBase{


    private String id;


    private String realName;

    private String nickName;

    private String userName;


    private String password;

    private String   sex;

    private Date birthday;

    private String address;


    private String phone;


    private String email;

    private String QQ;

    private String headImage;


    
    private Date registrationTime;

    private Date lastloginTime;

    private String status;

    private String hashCode;


    private SysUser operator;



    private Set<SysRole> roles;





    //拥有的功能
    List<SysModel> _functions;

    //功能菜单
    List<SysModel> _functionMenus;



    //包括功能 和 菜单 Key Value 用于验证 权限  和记录日志
    Map<String, SysModel> functions;




    public SysUser() {
    }

    public SysUser(String id) {
        this.id=id;
    }

    public String getId() {
        return id;
    }

    public void setId(String id) {
        this.id = id;
    }

    public String getRealName() {
        return realName;
    }

    public void setRealName(String realName) {
        this.realName = realName;
    }

    public String getNickName() {
        return nickName;
    }

    public void setNickName(String nickName) {
        this.nickName = nickName;
    }

    public String getUserName() {
        return userName;
    }

    public void setUserName(String userName) {
        this.userName = userName;
    }

    public String getPassword() {
        return password;
    }

    public void setPassword(String password) {
        this.password = password;
    }

    public String getSex() {
        return sex;
    }

    public void setSex(String sex) {
        this.sex = sex;
    }

    public Date getBirthday() {
        return birthday;
    }

    public void setBirthday(Date birthday) {
        this.birthday = birthday;
    }

    public String getAddress() {
        return address;
    }

    public void setAddress(String address) {
        this.address = address;
    }

    public String getPhone() {
        return phone;
    }

    public void setPhone(String phone) {
        this.phone = phone;
    }

    public String getEmail() {
        return email;
    }

    public void setEmail(String email) {
        this.email = email;
    }

    public String getQQ() {
        return QQ;
    }

    public void setQQ(String QQ) {
        this.QQ = QQ;
    }

    public String getHeadImage() {
        return headImage;
    }

    public void setHeadImage(String headImage) {
        this.headImage = headImage;
    }

    public Date getRegistrationTime() {
        return registrationTime;
    }

    public void setRegistrationTime(Date registrationTime) {
        this.registrationTime = registrationTime;
    }

    public Date getLastloginTime() {
        return lastloginTime;
    }

    public void setLastloginTime(Date lastloginTime) {
        this.lastloginTime = lastloginTime;
    }

    public String getStatus() {
        return status;
    }

    public void setStatus(String status) {
        this.status = status;
    }

    public String getHashCode() {
        return hashCode;
    }

    public void setHashCode(String hashCode) {
        this.hashCode = hashCode;
    }

    public Set<SysRole> getRoles() {
        return roles;
    }

    public void setRoles(Set<SysRole> roles) {
        this.roles = roles;
    }


    public List<SysModel> get_functions() {
        return _functions;
    }

    public void set_functions(List<SysModel> _functions) {
        this._functions = _functions;
    }

    public List<SysModel> get_functionMenus() {
        return _functionMenus;
    }

    public void set_functionMenus(List<SysModel> _functionMenus) {
        this._functionMenus = _functionMenus;
    }

    public Map<String, SysModel> getFunctions() {
        return functions;
    }

    public void setFunctions(Map<String, SysModel> functions) {
        this.functions = functions;
    }


    public SysUser getOperator() {
        return operator;
    }

    public void setOperator(SysUser operator) {
        this.operator = operator;
    }


    @Override
    public String toString() {
        return  this.getUserName();
    }
}
